package com.jyhz.gateway.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;
import java.util.HashSet;
import java.util.List;

/**
 * @author:谢君臣
 * @Date:2021/6/18-18:31
 * @version:1.0
 * @function:  请求路径白名单（不需要认证的路劲）
 */
@Component
@ConfigurationProperties(prefix = "jyhz.pathfilter")
public class PathFilterConfig {
    private List<String> whitepaths;

    public void setWhitepaths(List<String> whitepaths) {
        this.whitepaths = whitepaths;
    }

    public HashSet<String> getWhitepaths() {
        return new HashSet<>(whitepaths);
    }
}
